package com.tcs.teg.domain.accounts;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToMany;
import javax.persistence.Table;

import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;
import org.hibernate.annotations.Cascade;
import org.hibernate.annotations.CascadeType;

import common.money.Percentage;

@Entity
@Table(name = "T_USER_PREFERENCES")
public class UserPreferences implements Serializable {

	@Id
	@Column(name = "ID")
	private Integer id;

	@Column(name = "USER_LOGIN_ID") 
	private String userLoginId;

	@Column(name = "PREF_LANG")
	private String prefLang;

	
	
	public UserPreferences() {
	}

	/**
	 * Create a new account.
	 * @param number the account number
	 * @param name the name on the account
	 */
	public UserPreferences(String userLoginId, String prefLang) {
		this.userLoginId = userLoginId;
		this.prefLang = prefLang;
	}

	/**
	 * Returns the entity identifier used to internally distinguish this entity among other entities of the same type in
	 * the system. Should typically only be called by privileged data access infrastructure code such as an Object
	 * Relational Mapper (ORM) and not by application code.
	 * @return the internal entity identifier
	 */
	public Integer getId() {
		return id;
	}

	/**
	 * Sets the internal entity identifier - should only be called by privileged data access code (repositories that
	 * work with an Object Relational Mapper (ORM)). Should never be set by application code explicitly.
	 * @param entityId the internal entity identifier
	 */
	public void setId(Integer id) {
		this.id = id;
	}


	public String getUserLoginId() {
		return userLoginId;
	}

	public void setUserLoginId(String userLoginId) {
		this.userLoginId = userLoginId;
	}

	public String getPrefLang() {
		return prefLang;
	}

	public void setPrefLang(String prefLang) {
		this.prefLang = prefLang;
	}

	public String toString() {
		return "UserLoginId  = '" + userLoginId + "', prefLang = " + prefLang + "'";
	}
}